<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
    <!doctype html>
<html lang="zh-CN">
<head>
<base href="<%=basePath%>">
	<meta charset="UTF-8">

    <link rel="stylesheet" href="css/login.css">
    <script type="text/javascript" src="js/jquery.min.js"></script>
    
    <script type="text/javascript">
    $(function(){
    	$("#from").submit(function(){
    	if($("#n").val()==""){
        		alert("用户名不能为空");
        		return false;
        }else if($("#p").val()==""){
        		alert("密码不能为空");
        		return false;
        }else if($("#image").val()==""){
    		alert("验证码不能为空");
    		return false;
    	}	
    	return true;
    	});
    	
    });
    </script>
	<title>后台登陆</title>
</head>
<body>
	<div id="login_top">
		<div id="welcome">
			欢迎使用请假审批系统
		</div>
		<div id="back">
			<a href="#">返回首页</a>&nbsp;&nbsp; | &nbsp;&nbsp;
			<a href="#">帮助</a>
		</div>
	</div>
	
	<div id="login_center">
		<div id="login_area">
			<div id="login_form">
				<form action="<%=path %>/admin/login_isLogin.action" method="post" id="from">
					<div id="login_tip">
						用户登录&nbsp;&nbsp;UserLogin
					</div>
					<div><input type="text" id="n" class="username" name="admin.name"></div>
					<div><input type="text" id="p" class="pwd" name="admin.password"></div>
					<div><input type="radio" name="admin.role" value="0" checked="checked">学生&nbsp;&nbsp;
					<input type="radio" name="admin.role" value="1">老师&nbsp;&nbsp;
					<input type="radio" name="admin.role" value="2" >校领导&nbsp;&nbsp;
					<input type="radio" name="admin.role" value="3">学工处&nbsp;&nbsp;
					<input type="radio" name="admin.role" value="4">管理员
					  </div>
					<div id="btn_area">
						<input type="submit" name="submit" id="sub_btn" value="登&nbsp;&nbsp;录">&nbsp;&nbsp;
						<input type="text" class="verify" name="checkCode" id="image" data-validate="required:请填写密码">
						<img src="<%=path %>/admin/image.action" alt="" width="80" height="40"
						onclick="this.src='<%=path %>/admin/image.action?d='+Math.random()" title="点击图片刷新验证码" />
					</div>
				</form>
			</div>
		</div>
	</div>
	<div id="login_bottom">
		版权所有
	</div>
</body>
</html>